package com.tabjin.rfidsocket.pojo.bo;

import lombok.*;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;

@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
@Builder
@ToString
public class SysAclBO {
    private Integer id;
//    @NotBlank(message = "权限点码不可空")
    private String code = "";
    @NotBlank(message = "权限点名称不可为空")
    @Length(min = 2, max = 20, message = "权限点名称限制为2-20字之间")
    private String name;
    @NotNull(message = "权限模块必须指定")
    private Integer aclModuleId;
    @Length(min = 6, max = 100, message = "权限点url长度限制为6-100字之间")
    private String url;
    @NotNull(message = "权限点类型必须指定")
    @Min(value = 0, message = "权限点类型不合法")
    @Max(value = 2, message = "权限点类型不合法")
    private Integer type;
    @NotNull(message = "权限点状态必须指定")
    @Min(value = 0, message = "权限点状态不合法")
    @Max(value = 2, message = "权限点状态不合法")
    private Integer status;
    @NotNull(message = "权限点的展示顺序必须指定")
    private Integer seq;
    @Length(min = 0, max = 200, message = "权限点备注长度限制为6-200字之间")
    private String remark;
    private String operator;
    private Date operateTime;
    private String operateIp;
}